import { ASelectItemType } from '#/antd'
import { BaseTableState } from '#/core'
import { AuditLogItem } from '@/api/audit/auth/model/authorModel'
import { UpdateMaterialStatusReq } from '@/api/audit/content/model/materialModel'
import { QueryMaterialRequest } from '@/api/premium/content/model/materialModel'
import {
  MaterialItem,
  MaterialStatus,
} from '@/components/ItemList/MaterialList/types'

export interface ListMaterialItem extends MaterialItem {
  modifyAtlasPopVisible: boolean
}

export type MaterialTableState = BaseTableState<ListMaterialItem>

export type QueryMaterialForm = Omit<QueryMaterialRequest, 'current' | 'size'>

export type AuditMaterialDialogForm = Omit<UpdateMaterialStatusReq, 'id'>
export interface AuditMaterialDialogState {
  visiable: boolean
  currentItem?: MaterialItem
  auditLogs: AuditLogItem<MaterialStatus>[]
  formData: AuditMaterialDialogForm
  statusList: ASelectItemType[]
}

export enum AuditMode {
  QUICK,
  NORMAL,
}
